package com.spx.core.types.ui;

import com.spx.core.CoreActivator;
import com.spx.core.types.Activity;
import com.spx.core.types.Role;
import com.spx.core.types.User;
import com.spx.core.ui.views.ModelImageRegistry;

public class CoreImages
{

	private static CoreImages instance;

	private CoreImages()
	{
		init();
	}

	public synchronized static CoreImages getInstance()
	{
		if (instance == null)
		{
			instance = new CoreImages();
		}
		return instance;
	}

	public void init()
	{
		ModelImageRegistry ir = ModelImageRegistry.getInstance();
		ir.register(User.class, CoreActivator.getImageDescriptor("icons/user_16.gif").createImage());
		ir.register(Role.class, CoreActivator.getImageDescriptor("icons/role_16.gif").createImage());
		ir.register(Activity.class, CoreActivator.getImageDescriptor("icons/action_16.gif").createImage());
	}

}
